package com.firefly.admin.common.constant;

/**
 * 常量类
 *
 * @author hejishan
 */
public class Constants {

    public static class DeleteFlag {
        /**
         * 正常
         */
        public static final Integer NORMAL = 1;
        /**
         * 删除
         */
        public static final Integer DELETE = 0;
    }

    /**
     * http请求常量类
     */
    public static class Http {
        /**
         * POST请求
         */
        public static final String HTTP_METHOD_POST = "POST";
        /**
         * GET请求
         */
        public static final String HTTP_METHOD_GET = "GET";
    }

    public static class Redis {
        public static final String CONFIG_KEY = "ST_SYSTEM_CONFIG";
        public static final String DICTION_KEY = "ST_SYSTEM_DICTIONARY";
        public static final String WHITE_LIST_KEY = "ST_SYSTEM_WHITE_LIST";
        public static final String SIGN_AUTH_NONCE_KEY = "SIGN_AUTH_NONCE_KEY";
        public static final String RATE_LIMITER = "RATE_LIMITER";
        public static final String USER_TOKEN = "USER_TOKEN";
    }

    public static final String YES = "Y";
    public static final String CONTENT_TYPE_JSON = "application/json; charset=utf-8";

    /**
     * session常量类
     */
    public static class VerificationCode {
        public static final String NOT_OPEN_VERIFICATION_CODE = "N";
        public static final String CODE = "imgCode";
        public static final String CODE_DATA = "data";
        public static final String VERIFICATION_CODE_KEY = "verificationCodeKey";
    }

    public static class JwtToken {
        public static final String LOGIN_USER_KEY = "LOGIN_USER_KEY";
        public static final String USER_NAME = "USER_NAME";
    }

    public static class Status {
        public static final String ENABLE = "1";
        public static final String DISABLE = "0";
    }

    public static class NoticeStatus {

        public static final String UNRELEASED = "1";
        public static final String RELEASE = "2";
        public static final String REVOKE = "3";
    }

    public static class NoticeObjectType {
        public static final String ALL = "1";
        public static final String ORG = "2";
        public static final String USER = "3";
    }

    public static class NoticeType {
        public static final String SYSTEM_NOTICE = "1";
        public static final String USER_NOTICE = "2";
        public static final String USER_REMINDER = "3";
    }

    public static class JobStatus {
        public static final String START = "0";
        public static final String STOP = "1";
    }

    /**
     * 配置项常量类
     */
    public static class Properties {
        public static final String IS_OPEN_VERIFICATION_CODE = "isOpenVerificationCode";
        public static final String IS_OPEN_SENSITIVE_ENCRYPT = "isOpenSensitiveEncrypt";
    }

    public static final String USER_AGENT = "User-Agent";

    public static class Druid {
        public static final String ALLOW = "allow";
        public static final String DENY = "deny";
        public static final String LOGIN_USER_NAME = "loginUsername";
        public static final String LOGIN_PASSWORD = "loginPassword";
        public static final String RESET_ENABLE = "resetEnable";
    }

    public static final Long MENU_TOP_NODE = 0L;
    public static final Long ORG_TOP_NODE = 0L;

    public static final String PERMISSION_TYPE_MENU = "1";

    public static class OperateResult {
        public static final String SUCCESS = "0";
        public static final String FAIL = "1";
    }

    public static class LoginOperateType {
        public static final String LOGIN = "0";
        public static final String LOGOUT = "1";
        public static final String AUTO_LOGOUT = "2";
    }

    public static class LastExecuteResult {
        public static final String SUCCESS = "0";
        public static final String FAIL = "1";
        public static final String NOT_EXECUTED = "2";
    }

    public static class ExecutionPolicy {
        public static final String EXECUTE_IMMEDIATELY = "1";
        public static final String EXECUTE_ONCE = "2";
        public static final String ABANDON_EXECUTION = "3";
    }

    public static final String MESSAGE_ALREADY_READ = "1";
    public static final String MESSAGE_ALREADY_UNREAD = "0";

    public static final String MENU_TYPE_MENU = "1";

    public static class VerifyResult {
        public static final String SUCCESS = "1";
        public static final String FAIL = "0";
    }

    public static class OfficialAccountMenuStatus{
        public static final String PUBLISH = "1";
        public static final String UNPUBLISHED = "0";
    }

}
